Mod_python version 3.3.1 - How to Download and Install on Mac OS X
Sunday the 22nd of November, 2009

    mod_python  most recent diff


    version 3.3.1

      View the most recent changes for the mod_python port at: mod_python.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for mod_python.
      The raw portfile for mod_python 3.3.1 is located here:
      http://mod_python.darwinports.com/dports/www/mod_python/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/mod_python


      The mod_python Portfile 57375 2009-09-10 08:16:41Z ryandesign macports.org $

      PortSystem 1.0

      Name: mod_python
      Version: 3.3.1
      Revision: 1
      Category: www python
      Platform: darwin
      Maintainers: mww
      Description: Apache2 module that embeds Python within the server.
      Long Description: Mod_python is an Apache 2 module that embeds the Python interpreter within the server. With mod_python you can write web-based applications in Python that will run many times faster than traditional CGI and will have access to advanced features such as ability to retain database connections and other data between hits and access to Apache internals.

      Homepage: http://www.modpython.org/
      Master Sites: apache:httpd/modpython
      extract.suffix .tgz
      Checksums: sha1 e538170fd78e09408b6d8593da980b126a0fef93

      depends_build port:flex
      depends_lib port:apache2 port:python24

      Patch Files: patch-src-connobject.c.diff patch-dist-Makefile.in.diff

      configure.cppflags "-I${prefix}/include/python2.4"
      configure.ldflags-append "-Wl,-F${prefix}/Library/Frameworks"
      configure.args --with-apxs=${prefix}/apache2/bin/apxs --with-python=${prefix}/bin/python2.4 --with-flex=${prefix}/bin/flex --enable-so

      pre-destroot {
      xinstall -d -m 755 ${destroot}${prefix}/apache2/modules ${destroot}${prefix}/share/doc
      file copy ${worksrcpath}/doc-html ${destroot}${prefix}/share/doc/${name}
      }

      destroot.violate_mtree yes

      post-install {
      ui_msg "########################################################"
      ui_msg "# to enable mod_python add"
      ui_msg "# LoadModule python_module modules/mod_python.so"
      ui_msg "# to your apache2 config file:"
      ui_msg "# ${prefix}/apache2/conf/httpd.conf"
      ui_msg "########################################################"
      }

      livecheck.type regex
      livecheck.url http://httpd.apache.org/modules/python-download.cgi
      livecheck.regex mod_python-(\[0-9\\.\]+)\\.tgz


    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/mod_python
      % sudo port install mod_python
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching mod_python
      ---> Verifying checksum for mod_python
      ---> Extracting mod_python
      ---> Configuring mod_python
      ---> Building mod_python with target all
      ---> Staging mod_python into destroot
      ---> Installing mod_python
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using mod_python with these commands:
      %  man mod_python
      % apropos mod_python
      % which mod_python
      % locate mod_python

     Where to find more information:

    Darwin Ports



    Lightbox this page.